<template>
	<view class="content">
		<view class="head-wrap">
			<view class="door-head-wrap">
				<image class="img-door-head" src="../../static/images/mengtou.jpg"  />
				<view class="info-wrap">
					<view class="store-info-box">
						<view class="store-name">{{obtStoreInfo.StoreName}}</view>
						<view class="store-status">{{obtStoreInfo.StoreStatus}}</view>
						<view class="store-share icon-box"><image class="icon-img icon-shareit" src="../../static/images/ShareIt.png" mode="widthFix" /></view>
						<view class="store-phone icon-box"><image class="icon-img icon-phone" src="../../static/images/Phone.png" mode="widthFix" /></view>					
					</view>
					<view class="store-Address"><image class="icon-positioning" src="../../static/images/Positioning.png" mode="widthFix" />{{obtStoreInfo.Address}}</view>
				</view>
			</view>
			<ModuleNotification :value="obtHomePageData.topicList" />
		</view>
		<HomeProductBox title="新品上市" :value="obtHomePageData.newGoodsList" iconsrc="../../static/images/31_New.png" />
		<HomeProductBox title="近期热卖" :value="obtHomePageData.hotGoodsList" iconsrc="../../static/images/Popular.png" />
		<CompBottomLine />
	</view>
</template>

<script>
	import * as types from "@/store/types.js";	
	import ModuleNotification from "@/components/Module_Notification/Module_Notification.vue"
	import HomeProductBox from "@/components/Module_HomeProductBox/Module_HomeProductBox.vue"
	import CompBottomLine from "@/components/Comp_BottomLine/Comp_BottomLine.vue"

	export default {
		components:{
			ModuleNotification,
			HomeProductBox,
			CompBottomLine
		},
		data() {
			return {
				title: 'Hello'
			}
		},
		computed: {
			//取出店铺名称
			obtStoreInfo() {
				return this.$store.getters.gstoreinfo;
			},
			obtHomePageData(){
				return this.$store.getters.ghomepagedata;
			}
		},
		methods: {
			load:function(){
				this.$store.dispatch(types.AHomePageData, '');
				// this.$store.dispatch(types.AProductList, '?size=10&page=0');
			}
		},
		onLoad() {
			this.load();
		}
	}
</script>

<style lang="less" scoped>
	@import url("./index.less");
</style>
